package com.heima.article.feign;

import com.heima.article.dto.ApBehaviorEntry;
import com.heima.article.dto.ArticleInfoDtoV2;
import com.heima.article.dto.EntryDto;
import com.heima.common.dto.ResponseResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient("leadnews-behavior")
public interface BehaviorFeign {

    /**
     * 根据entry_id查询entry
     *
     * @param dto
     * @return
     */
    @PostMapping("/api/v1/behavior_entry/getEntry")
    public ResponseResult<ApBehaviorEntry> getEntry(@RequestBody EntryDto dto);

    @PostMapping("/api/v1/behavior_entry/handle/behavior")
    public ResponseResult handleBehavior(@RequestBody ArticleInfoDtoV2 dto);

}
